<template>
  <div style="position: relative;">
    <div class="photoDevice" v-if="cameraNum">设备编号：{{ cameraNum }}</div>
    <i class="el-icon-refresh refreshBtn" @click="reloadPage()"></i>
    <i class="el-icon-sort refreshBtn1" @click="loginOut()"></i>
    <i class="el-icon-picture refreshBtn2" v-if="isShanyi" @click="getDeptTreeAndLoginChecked(7)"></i>
    <!-- el-icon-picture -->
    <!-- 上海凤凰馨院 isShanyi-->
    <div class="photoRegisterBg" v-if="isShanyi">
      <div class="header">
        <div class="headerFixed">
          <img :src="shanyilogo" alt="" class="headerFixed_image" />
          <div class="headerFixed_text">凤凰馨院</div>
        </div>
        <div class="headerContainers" :class="device !== 'mobile' ? '' : 'active'">
          <!-- <img :src="pifubinglogo" alt="" class="header_image"/> -->
          <div class="header_title hcqStyle8">脸部皮肤健康智能检测仪</div>
        </div>
      </div>
      <div class="main-container-content photoRegisterBoxs-content">
        <!-- <div class="photoregisterImgContainers">
          <img src="@/assets/images/photoregister.png" alt="" class="photoregisterImg" @click="goToHref">
          <div class="qrcodeContainers">
            <div  class="qrcode" ref="qrCodeDiv"></div>
          </div>
         
        </div> -->
        <div class="photoRegisterBoxs">
          <el-form ref="baseInfoForm" :inline="true" :model="baseInfo" :rules="baseInfoFormRules" label-position="left"
            label-width="120px">
            <div class="photoRegisterBoxs_div">
            <!-- <div class="dialogTitle">
              <span class="titleLine"></span>
              <span class="name">基本信息</span>
            </div> -->
            <!--  @blur="updateMsgInfosEvent()" -->
            <el-row :gutter="10">
              <el-col :xs='24' :sm="15" :md="15" :lg="15" :xl="15">
                <el-form-item label="体检号" prop="checkinCode" class="shanyiForm">
                  <el-input v-model="baseInfo.checkinCode" style="width:100%" placeholder="请输入体检号" class="photoRegister_formItem_input">
                  </el-input>
                </el-form-item>
              </el-col>
              <el-col :xs='24' :sm="9" :md="9" :lg="9" :xl="9">
                <el-button @click="resetLoadInput" class="clearBtn">清 空</el-button>
                <el-button class="registerBtn rightBtn" style="margin-left:10px;" @click="updateMsgInfosEvent()">
                  检 索
                </el-button>

              </el-col>
            </el-row>
            <el-row>
              <div class="baseInfoContainers">
                <el-table :data="tableData" height="150" border style="width: 100%">
                  <el-table-column prop="checkinCode" label="体检号" width="180">
                  </el-table-column>
                  <el-table-column prop="patientName" label="姓名" width="180">
                  </el-table-column>
                  <el-table-column prop="sex" label="性别" width="180">
                    <template slot-scope="scope">
                      <dict-tag :options="dict.type.sys_user_sex" :value="scope.row.sex" />
                    </template>
                  </el-table-column>
                  <el-table-column prop="birthDate" label="出生年月日" width="180">
                  </el-table-column>
                  <el-table-column prop="patientPhone" label="手机号" width="180">
                  </el-table-column>
                  <el-table-column prop="remark" label="备注">
                  </el-table-column>

                </el-table>
              </div>

            </el-row>


            <div class="imageBox" style="margin-top:40px;">
              <div class="imageSmallBox">
                <img :src="personcenter" alt="" class="header_image" />
                <div>正脸</div>
              </div>
              <div class="imageSmallBox">
                <img :src="personleft" alt="" class="header_image" />
                <div>左脸</div>
              </div>
              <div class="imageSmallBox">
                <img :src="personright" alt="" class="header_image" />
                <div>右脸</div>
              </div>

            </div>
            <!-- getDeptTreeAndLoginChecked(6) -->
            <div class="registerBtnContainers">
              <el-button @click="registAndPhotoEvent" class="registerBtn rightBtn" style="margin-left:0px;">立 即 拍 照
              </el-button>
            </div>
            <div class="textBox" style="margin-top:40px;">
              <div class="textBoxTitle">拍摄规范:</div>
              <div class="textBoxLine">
                1、毛发问题:拍照时，面部区域需干净整洁、无异物、无毛发。
              </div>
              <div class="textBoxLine">
                2、素颜问题:拍照时，需纯素颜拍摄，化妆品会覆盖表皮问题。
              </div>
              <div class="textBoxLine">
                3、角度问题:拍摄人员需紧闭双眼，下颚轻放在下颚托上，额头顶住额头托，调整好头部摆放位置，防止出现俯视、仰视等状况。
              </div>

            </div>
          </div>
          </el-form>

        </div>
      </div>
      <!-- 根据身份证号、姓名、手机号查询多个病人时需要选择 -->
      <!-- 选择顾客 -->
      <el-dialog v-dialogDrag :class="device !== 'mobile' ? '' : 'active'" :close-on-click-modal="false"
        :visible.sync="patientVisible" :width="device !== 'mobile' ? '40%' : '85%'"
        class="nopaddingDailog photoPaitentDailog" title="选择顾客">
        <div class="formBox">
          <el-table :data="patientVisibleList" border style="width: 100%">
            <el-table-column :show-overflow-tooltip="true" align="center" label="顾客姓名" prop="patientName" sortable />
            <el-table-column :show-overflow-tooltip="true" align="center" label="顾客手机号" prop="patientPhone" sortable />
            <el-table-column align="center" label="性别" prop="sex" sortable>
              <template slot-scope="scope">
                <dict-tag :options="dict.type.sys_user_sex" :value="scope.row.sex" />
              </template>
            </el-table-column>
            <el-table-column align="center" label="年龄" prop="birthDateCopy" sortable width="80" />
            <el-table-column align="center" class-name="small-padding fixed-width" fixed="right" label="操作" width="100">
              <template slot-scope="scope">
                <el-button icon="el-icon-caret-right" size="mini" type="text" class="paitentBoxBtn"
                  @click="getDeptTreeAndLoginChecked(4, scope.row)">点击选择
                </el-button>
              </template>
            </el-table-column>
          </el-table>
        </div>
      </el-dialog>

      <div class="dec">
        Copyright © 霏图皮博士提供技术支持
      </div>

    </div>
    <!--上海市皮肤病医院-->
    <div class="photoRegisterBg" v-else-if="isAcneSection">
      <div class="header">
        <div class="headerContainers" :class="device !== 'mobile' ? '' : 'active'">
          <img :src="pifubinglogo" alt="" class="header_image" />
          <div class="header_title hcqStyle8">皮肤智能照片采集</div>
        </div>
      </div>
      <div class="main-container-content photoRegisterBoxs-content">
        <!-- <div class="photoregisterImgContainers">
          <img src="@/assets/images/photoregister.png" alt="" class="photoregisterImg" @click="goToHref">
          <div class="qrcodeContainers">
            <div  class="qrcode" ref="qrCodeDiv"></div>
          </div>
         
        </div> -->
        <div class="photoRegisterBoxs">
          <el-form ref="baseInfoFormA" :inline="true" :model="baseInfo" :rules="baseInfoFormRulesA"
            label-position="left" label-width="180px">
            <div class="photoRegisterBoxs_div">
            <div class="dialogTitle">
              <span class="titleLine"></span>
              <span class="name">基本信息</span>
              <div class="searchAllBtn" @click="getDeptTreeAndLoginChecked(7)"><i
                  class="el-icon-s-home homeIcon"></i>本地照片库
              </div>
            </div>
            <el-row :gutter="10">
              <el-col :xs='24' :sm="24" :md="24" :lg="24" :xl="24">
                <el-form-item label="身份证号">
                  <el-input ref="saveTagInput" v-model="baseInfo.idNum" placeholder="请输入身份证号"
                    class="photoRegister_formItem_input" @input="inputIdNum"
                    @blur="getDeptTreeAndLoginChecked(2, baseInfo.idNum)">
                    <i slot="suffix" class="el-input__icon el-icon-search"></i>
                  </el-input>
                </el-form-item>
              </el-col>
              <el-col :xs='24' :sm="24" :md="24" :lg="24" :xl="24">
                <el-form-item label="门诊卡号" prop="cardNumber">
                  <el-input v-model="baseInfo.cardNumber" placeholder="门诊卡号" class="photoRegister_formItem_input"
                    @input="inputIdNum">
                  </el-input>
                </el-form-item>
              </el-col>
              <el-col :xs='24' :sm="24" :md="24" :lg="24" :xl="24">
                <div style="display:flex;align-items:center;justify-content:center">
                  <el-button @click="resetLoad" class="clearBtn">清 空</el-button>
                <el-button v-if="!isRegister" class="registerBtn rightBtn" @click="getDeptTreeAndLoginChecked(8)">
                  登 记
                </el-button>
                <el-button @click="getDeptTreeAndLoginChecked(6)" class="registerBtn rightBtn" v-if="isRegister">立即拍照
                </el-button>
                </div>
             

              </el-col>


            </el-row>

            <div class="imageBox" style="margin-top:40px;">
              <div class="imageSmallBox">
                <img :src="personcenter" alt="" class="header_image" />
                <div>正脸</div>
              </div>
              <div class="imageSmallBox">
                <img :src="personleft" alt="" class="header_image" />
                <div>左脸</div>
              </div>
              <div class="imageSmallBox">
                <img :src="personright" alt="" class="header_image" />
                <div>右脸</div>
              </div>

            </div>
            <div class="textBox" style="margin-top:40px;">
              <div class="textBoxTitle">拍摄规范:</div>
              <div class="textBoxLine">
                1、毛发问题:拍照时，面部区域需干净整洁、无异物、无毛发。
              </div>
              <div class="textBoxLine">
                2、素颜问题:拍照时，需纯素颜拍摄，化妆品会覆盖表皮问题。
              </div>
              <div class="textBoxLine">
                3、角度问题:拍摄人员需紧闭双眼，下颚轻放在下颚托上，额头顶住额头托，调整好头部摆放位置，防止出现俯视、仰视等状况。
              </div>

            </div>
          </div>
          </el-form>

        </div>
      </div>
      <!-- 根据身份证号、姓名、手机号查询多个病人时需要选择 -->
      <!-- 选择顾客 -->
      <el-dialog v-dialogDrag :class="device !== 'mobile' ? '' : 'active'" :close-on-click-modal="false"
        :visible.sync="patientVisible" :width="device !== 'mobile' ? '40%' : '85%'"
        class="nopaddingDailog photoPaitentDailog" title="选择顾客">
        <div class="formBox">
          <el-table :data="patientVisibleList" border style="width: 100%">
            <el-table-column :show-overflow-tooltip="true" align="center" label="顾客姓名" prop="patientName" sortable />
            <el-table-column :show-overflow-tooltip="true" align="center" label="顾客手机号" prop="patientPhone" sortable />
            <el-table-column align="center" label="性别" prop="sex" sortable>
              <template slot-scope="scope">
                <dict-tag :options="dict.type.sys_user_sex" :value="scope.row.sex" />
              </template>
            </el-table-column>
            <el-table-column align="center" label="年龄" prop="birthDateCopy" sortable width="80" />
            <el-table-column align="center" class-name="small-padding fixed-width" fixed="right" label="操作" width="100">
              <template slot-scope="scope">
                <el-button icon="el-icon-caret-right" size="mini" type="text" class="paitentBoxBtn"
                  @click="getDeptTreeAndLoginChecked(4, scope.row)">点击选择
                </el-button>
              </template>
            </el-table-column>
          </el-table>
        </div>
      </el-dialog>

      <div class="dec">
        Copyright © 上海市皮肤病医院提供技术支持
      </div>

    </div>
    <!-- 上海国际医学中心 isInternCenter-->
    <div class="photoRegisterBg" v-else-if="isInternCenter">
      <div class="header">
        <div class="headerContainers" :class="device !== 'mobile' ? '' : 'active'">
          <img :src="InternCenterlogo" alt="" class="header_image" />
          <div class="header_title hcqStyle8">皮肤智能照片采集</div>
        </div>
      </div>
      <div class="main-container-content photoRegisterBoxs-content">
        <!-- <div class="photoregisterImgContainers">
          <img src="@/assets/images/photoregister.png" alt="" class="photoregisterImg" @click="goToHref">
          <div class="qrcodeContainers">
            <div  class="qrcode" ref="qrCodeDiv"></div>
          </div>
         
        </div> -->
        <div class="photoRegisterBoxs">
          <el-form ref="baseInfoFormA" :inline="true" :model="baseInfo" :rules="baseInfoFormRulesA"
            label-position="left" label-width="180px">
            <div class="photoRegisterBoxs_div">
            <div class="dialogTitle">
              <span class="titleLine"></span>
              <span class="name">基本信息</span>
              <div class="searchAllBtn" @click="getDeptTreeAndLoginChecked(7)"><i
                  class="el-icon-s-home homeIcon"></i>本地照片库
              </div>
            </div>
            <el-row :gutter="10">
              <!-- <el-col :xs='24' :sm="24" :md="24" :lg="24" :xl="24">
                <el-form-item label="身份证号">
                  <el-input ref="saveTagInput" v-model="baseInfo.idNum" placeholder="请输入身份证号"
                    class="photoRegister_formItem_input" @input="inputIdNum"
                    @blur="getDeptTreeAndLoginChecked(2, baseInfo.idNum)">
                    <i slot="suffix" class="el-input__icon el-icon-search"></i>
                  </el-input>
                </el-form-item>
              </el-col> -->
              <el-col :xs='24' :sm="24" :md="24" :lg="24" :xl="24">
                <el-form-item label="门诊卡号" prop="cardNumber">
                  <el-input v-model="baseInfo.cardNumber" placeholder="门诊卡号" class="photoRegister_formItem_input"
                    @input="inputIdNum">
                  </el-input>
                </el-form-item>
              </el-col>
              <el-col :xs='24' :sm="24" :md="24" :lg="24" :xl="24">
                <div style="display:flex;align-items:center;justify-content:center">
                  <el-button @click="resetLoad" class="clearBtn">清 空</el-button>
                <el-button v-if="!isRegister" class="registerBtn rightBtn" @click="getDeptTreeAndLoginChecked(8)">
                  登 记
                </el-button>
                <el-button @click="getDeptTreeAndLoginChecked(6)" class="registerBtn rightBtn" v-if="isRegister">立即拍照
                </el-button>
                </div>
             

              </el-col>


            </el-row>

            <div class="imageBox" style="margin-top:40px;">
              <div class="imageSmallBox">
                <img :src="personcenter" alt="" class="header_image" />
                <div>正脸</div>
              </div>
              <div class="imageSmallBox">
                <img :src="personleft" alt="" class="header_image" />
                <div>左脸</div>
              </div>
              <div class="imageSmallBox">
                <img :src="personright" alt="" class="header_image" />
                <div>右脸</div>
              </div>

            </div>
            <div class="textBox" style="margin-top:40px;padding-bottom:20px;">
              <div class="textBoxTitle">拍摄规范:</div>
              <div class="textBoxLine">
                1、毛发问题:拍照时，面部区域需干净整洁、无异物、无毛发。
              </div>
              <div class="textBoxLine">
                2、素颜问题:拍照时，需纯素颜拍摄，化妆品会覆盖表皮问题。
              </div>
              <div class="textBoxLine">
                3、角度问题:拍摄人员需紧闭双眼，下颚轻放在下颚托上，额头顶住额头托，调整好头部摆放位置，防止出现俯视、仰视等状况。
              </div>

            </div>
          </div>
          </el-form>

        </div>
      </div>
      <!-- 根据身份证号、姓名、手机号查询多个病人时需要选择 -->
      <!-- 选择顾客 -->
      <el-dialog v-dialogDrag :class="device !== 'mobile' ? '' : 'active'" :close-on-click-modal="false"
        :visible.sync="patientVisible" :width="device !== 'mobile' ? '40%' : '85%'"
        class="nopaddingDailog photoPaitentDailog" title="选择顾客">
        <div class="formBox">
          <el-table :data="patientVisibleList" border style="width: 100%">
            <el-table-column :show-overflow-tooltip="true" align="center" label="顾客姓名" prop="patientName" sortable />
            <el-table-column :show-overflow-tooltip="true" align="center" label="顾客手机号" prop="patientPhone" sortable />
            <el-table-column align="center" label="性别" prop="sex" sortable>
              <template slot-scope="scope">
                <dict-tag :options="dict.type.sys_user_sex" :value="scope.row.sex" />
              </template>
            </el-table-column>
            <el-table-column align="center" label="年龄" prop="birthDateCopy" sortable width="80" />
            <el-table-column align="center" class-name="small-padding fixed-width" fixed="right" label="操作" width="100">
              <template slot-scope="scope">
                <el-button icon="el-icon-caret-right" size="mini" type="text" class="paitentBoxBtn"
                  @click="getDeptTreeAndLoginChecked(4, scope.row)">点击选择
                </el-button>
              </template>
            </el-table-column>
          </el-table>
        </div>
      </el-dialog>

      <div class="dec">
        Copyright © 上海国际医学中心(SIMC)提供技术支持
      </div>

    </div>
    <!-- 霏图演示环境 -->
    <div class="photoRegisterBg" v-else-if="isfeitu">
      <div class="header">
        <div class="headerContainers" :class="device !== 'mobile' ? '' : 'active'">
          <img :src="avatarLogoImg" alt="" class="header_image" />
          <div class="header_title hcqStyle8">皮肤智能照片采集</div>
        </div>
      </div>
      <div class="main-container-content photoRegisterBoxs-content">
        <!-- <div class="photoregisterImgContainers">
          <img src="@/assets/images/photoregister.png" alt="" class="photoregisterImg" @click="goToHref">
          <div class="qrcodeContainers">
            <div  class="qrcode" ref="qrCodeDiv"></div>
          </div>
         
        </div> -->
        <div class="photoRegisterBoxs">
          <el-form ref="baseInfoFormA" :inline="true" :model="baseInfo" :rules="baseInfoFormRulesA"
            label-position="left" label-width="180px">
            <div class="photoRegisterBoxs_div">
            <div class="dialogTitle">
              <span class="titleLine"></span>
              <span class="name">基本信息</span>
              <div class="searchAllBtn" @click="getDeptTreeAndLoginChecked(7)"><i
                  class="el-icon-s-home homeIcon"></i>本地照片库
              </div>
            </div>
            <el-row :gutter="10">
              <!-- <el-col :xs='24' :sm="24" :md="24" :lg="24" :xl="24">
                <el-form-item label="身份证号">
                  <el-input ref="saveTagInput" v-model="baseInfo.idNum" placeholder="请输入身份证号"
                    class="photoRegister_formItem_input" @input="inputIdNum"
                    @blur="getDeptTreeAndLoginChecked(2, baseInfo.idNum)">
                    <i slot="suffix" class="el-input__icon el-icon-search"></i>
                  </el-input>
                </el-form-item>
              </el-col> -->
              <el-col :xs='24' :sm="24" :md="24" :lg="24" :xl="24">
                <el-form-item label="门诊卡号" prop="cardNumber">
                  <el-input v-model="baseInfo.cardNumber" placeholder="门诊卡号" class="photoRegister_formItem_input"
                    @input="inputIdNum">
                  </el-input>
                </el-form-item>
              </el-col>
              <el-col :xs='24' :sm="24" :md="24" :lg="24" :xl="24">
                <div style="display:flex;align-items:center;justify-content:center">
                  <el-button @click="resetLoad" class="clearBtn">清 空</el-button>
                <el-button v-if="!isRegister" class="registerBtn rightBtn" @click="getDeptTreeAndLoginChecked(8)">
                  登 记
                </el-button>
                <el-button @click="getDeptTreeAndLoginChecked(6)" class="registerBtn rightBtn" v-if="isRegister">立即拍照
                </el-button>
                </div>
             

              </el-col>


            </el-row>

            <div class="imageBox" style="margin-top:40px;">
              <div class="imageSmallBox">
                <img :src="personcenter" alt="" class="header_image" />
                <div>正脸</div>
              </div>
              <div class="imageSmallBox">
                <img :src="personleft" alt="" class="header_image" />
                <div>左脸</div>
              </div>
              <div class="imageSmallBox">
                <img :src="personright" alt="" class="header_image" />
                <div>右脸</div>
              </div>

            </div>
            <div class="textBox" style="margin-top:40px;padding-bottom:20px;">
              <div class="textBoxTitle">拍摄规范:</div>
              <div class="textBoxLine">
                1、毛发问题:拍照时，面部区域需干净整洁、无异物、无毛发。
              </div>
              <div class="textBoxLine">
                2、素颜问题:拍照时，需纯素颜拍摄，化妆品会覆盖表皮问题。
              </div>
              <div class="textBoxLine">
                3、角度问题:拍摄人员需紧闭双眼，下颚轻放在下颚托上，额头顶住额头托，调整好头部摆放位置，防止出现俯视、仰视等状况。
              </div>

            </div>
          </div>
          </el-form>

        </div>
      </div>
      <!-- 根据身份证号、姓名、手机号查询多个病人时需要选择 -->
      <!-- 选择顾客 -->
      <el-dialog v-dialogDrag :class="device !== 'mobile' ? '' : 'active'" :close-on-click-modal="false"
        :visible.sync="patientVisible" :width="device !== 'mobile' ? '40%' : '85%'"
        class="nopaddingDailog photoPaitentDailog" title="选择顾客">
        <div class="formBox">
          <el-table :data="patientVisibleList" border style="width: 100%">
            <el-table-column :show-overflow-tooltip="true" align="center" label="顾客姓名" prop="patientName" sortable />
            <el-table-column :show-overflow-tooltip="true" align="center" label="顾客手机号" prop="patientPhone" sortable />
            <el-table-column align="center" label="性别" prop="sex" sortable>
              <template slot-scope="scope">
                <dict-tag :options="dict.type.sys_user_sex" :value="scope.row.sex" />
              </template>
            </el-table-column>
            <el-table-column align="center" label="年龄" prop="birthDateCopy" sortable width="80" />
            <el-table-column align="center" class-name="small-padding fixed-width" fixed="right" label="操作" width="100">
              <template slot-scope="scope">
                <el-button icon="el-icon-caret-right" size="mini" type="text" class="paitentBoxBtn"
                  @click="getDeptTreeAndLoginChecked(4, scope.row)">点击选择
                </el-button>
              </template>
            </el-table-column>
          </el-table>
        </div>
      </el-dialog>

      <div class="dec">
        Copyright © 霏图皮博士提供技术支持
      </div>

    </div>
    <!-- 其他医院机构-->
    <div class="photoRegisterBg" v-else>
      <div class="header" v-if="isSkin">
        <div class="headerContainers" :class="device !== 'mobile' ? '' : 'active'">
          <img :src="pifubinglogo" alt="" class="header_image" />
          <div class="header_title hcqStyle8">皮肤智能照片采集</div>
        </div>
      </div>
      <div class="header" v-else>
        <!-- {{ hospital.deptName }} -->
        <div class="headerContainers" :class="device !== 'mobile' ? '' : 'active'">
          <img :src="avatarLogoImg" alt="" class="header_image" />
          <div class="header_title hcqStyle7">霏图皮博士脸部拍照仪登记</div>
        </div>

      </div>
      <div class="main-container-content photoRegisterBoxs-content">
        <!-- <div class="photoregisterImgContainers">
          <img src="@/assets/images/photoregister.png" alt="" class="photoregisterImg" @click="goToHref">
          <div class="qrcodeContainers">
            <div  class="qrcode" ref="qrCodeDiv"></div>
          </div>
         
        </div> -->
        <div class="photoRegisterBoxs">
       
          <el-form ref="baseInfoForm" :inline="true" :model="baseInfo" :rules="baseInfoFormRules" label-position="left"
            label-width="180px">
            <!-- <div class="backBtn">
                <i class="el-icon-s-home backBtnIcon"></i>
                返回全流程系统
            </div> -->
            <div class="photoRegisterBoxs_div">

            
            <div class="dialogTitle">
              <!-- <img :src="require('@/assets/images/dialogTitle.png')" alt="" class="image" /> -->
              <!-- el-icon-s-home-->
              <span class="titleLine"></span>
              <span class="name">基本信息</span>
              <div class="searchAllBtn" @click="getDeptTreeAndLoginChecked(7)"><i
                  class="el-icon-s-home homeIcon"></i>本地照片库
              </div>
            </div>
            <el-row :gutter="10">
              <el-col :xs='20' :sm="20" :md="20" :lg="20" :xl="20">
                <el-form-item label="顾客ID" prop="patientId">
                  <el-input v-model="queryParams.patientId" placeholder="顾客ID" class="photoRegister_formItem_input"
                    @keyup.enter.native="getDeptTreeAndLoginChecked(1)" @blur="getDeptTreeAndLoginChecked(1)">
                    <i slot="suffix" class="el-input__icon el-icon-search"></i>
                  </el-input>
                </el-form-item>
              </el-col>
              <el-col :xs='4' :sm="4" :md="4" :lg="3" :xl="3">
                <el-form-item label="" label-width="0px">
                  <el-button class="registerBtn" size="small" @click.stop="handleClickButton(1)">搜索顾客ID
                  </el-button>
                </el-form-item>
              </el-col>
            </el-row>
            <el-row :gutter="10">
              <!-- :disabled="baseInfoInput" -->
              <el-col :xs='24' :sm="24" :md="24" :lg="24" :xl="24" v-if="isShowIDStatus">
                <el-form-item label="无身份证登记" label-width="220px" class="formOther">
                  <div class="photoRegister_formItem_radio">
                    <el-radio v-model="isIdNum" :label="true" @input="confirmIsIdNum">否</el-radio>
                    <el-radio v-model="isIdNum" :label="false" @input="confirmIsIdNum">是</el-radio>
                  </div>
                </el-form-item>

              </el-col>
              <el-col :xs='24' :sm="24" :md="24" :lg="24" :xl="24" v-show="isIdNum">
                <el-form-item label="身份证号" :prop="isIdNum ? 'idNum' : ''">
                  <el-input ref="saveTagInput" :disabled="baseInfoInput" v-model="baseInfo.idNum" placeholder="请输入身份证号"
                    class="photoRegister_formItem_input" @blur="getDeptTreeAndLoginChecked(2, baseInfo.idNum)">
                    <!--             @focus="getSFZ" -->
                    <i slot="suffix" class="el-input__icon el-icon-search"></i>
                  </el-input>
                </el-form-item>
              </el-col>
            </el-row>
            <el-row :gutter="10">
              <el-col :xs='24' :sm="12" :md="12" :lg="12" :xl="12">
                <el-form-item label="姓名" prop="patientName">
                  <el-input v-model="baseInfo.patientName" placeholder="请输入姓名" class="photoRegister_formItem_input"
                    @blur="getDeptTreeAndLoginChecked(3, baseInfo.patientName)">
                    <i slot="suffix" class="el-input__icon el-icon-search"></i>
                  </el-input>
                </el-form-item>
              </el-col>
              <el-col :xs='24' :sm="12" :md="12" :lg="12" :xl="12">
                <el-form-item label="卡号" prop="cardNumber">
                  <el-input v-model="baseInfo.cardNumber" placeholder="就诊卡号" class="photoRegister_formItem_input">
                    <!--                    <i slot="suffix" class="el-input__icon el-icon-search"></i>-->
                  </el-input>
                </el-form-item>
              </el-col>
              <el-col :xs='24' :sm="12" :md="12" :lg="12" :xl="12">
                <el-form-item label="性别" prop="sex">
                  <el-select v-model="baseInfo.sex" clearable placeholder="性别" :popper-append-to-body="false" class="photoRegister_formItem_input">
                    <el-option v-for="dict in dict.type.sys_user_sex" :key="dict.value" :label="dict.label"
                      :value="dict.value" />
                  </el-select>
                </el-form-item>
              </el-col>
              <el-col :xs='24' :sm="12" :md="12" :lg="12" :xl="12">
                <el-form-item label="出生年月" prop="birthDate">
                  <el-date-picker v-model="baseInfo.birthDate" placeholder="选择出生年月" :append-to-body="false" class="photoRegister_formItem_input"
                    type="date" value-format="yyyy-MM-dd">
                  </el-date-picker>
                </el-form-item>
              </el-col>
              <el-col :xs='24' :sm="12" :md="12" :lg="12" :xl="12">
                <el-form-item label="手机号" prop="patientPhone">
                  <el-input v-model="baseInfo.patientPhone" :maxlength="11" type="number" placeholder="请输入手机号"
                    class="photoRegister_formItem_input" />
                </el-form-item>
              </el-col>

              <el-col :xs='24' :sm="12" :md="12" :lg="12" :xl="12">
                <el-form-item :prop="isSFZ ? 'area' : ''" label="患者地址">
                  <el-cascader v-model="baseInfo.area" :clearable="true" :options="areaList" :append-to-body="false"
                    :props="{ children: 'childrenList', value: 'id', label: 'name' }"
                    class="picker-form photoRegister_formItem_input"  placeholder="省,市,区">
                  </el-cascader>
                </el-form-item>
              </el-col>
              <el-col :xs='24' :sm="12" :md="12" :lg="12" :xl="12">
                <el-form-item label="详细地址" prop="address">
                  <el-input v-model="baseInfo.address" placeholder="小区/乡村名称"
                    class="photoRegister_formItem_input"></el-input>
                </el-form-item>
              </el-col>
              <!-- <el-col :xs='24' :sm="12" :md="12" :lg="12" :xl="12">
                  <el-form-item label="微信号" prop="wxNum">
                      <el-input v-model="baseInfo.wxNum" placeholder="微信小程序登录后自动获取"
                          class="photoRegister_formItem_input"></el-input>
                  </el-form-item>
              </el-col> -->
              <el-col :xs='24' :sm="12" :md="12" :lg="12" :xl="12">
                <el-form-item label="职业" prop="job">
                  <el-input v-model="baseInfo.job" placeholder="请输入职业" class="photoRegister_formItem_input"></el-input>
                </el-form-item>
              </el-col>
              <!-- <el-col :xs='24' :sm="12" :md="8" :lg="7" :xl="7">
                  <el-form-item label="是否拍VISIA" label-width="100px">
                      <el-radio-group v-model="baseInfo.isNeedVisi">
                          <el-radio label="0">不需要</el-radio>
                          <el-radio label="1">需要</el-radio>
                      </el-radio-group>
                  </el-form-item>
              </el-col>
              <el-col :xs='24' :sm="12" :md="8" :lg="7" :xl="7">

              </el-col> -->

            </el-row>
          </div>
          <div class="photoRegisterBoxs_div">
            <div class="dialogTitle" style="margin-top:10px;">
              <span class="titleLine"></span>
              <!-- <img :src="require('@/assets/images/dialogTitle.png')" alt="" class="image" /> -->
              <span class="name">医疗信息</span>
            </div>
            <el-row :gutter="10">
              <el-col :xs='24' :sm="12" :md="12" :lg="12" :xl="12">
                <el-form-item label="顾客性质" prop="properties">
                  <el-select v-model="baseInfo.properties" placeholder="请选择顾客性质" :popper-append-to-body="false" class="photoRegister_formItem_input">
                    <el-option v-for="dict in dict.type.sys_patient_properties" :key="dict.value" :label="dict.label"
                      :value="dict.value" />
                  </el-select>
                </el-form-item>
              </el-col>
              <el-col :xs='24' :sm="12" :md="12" :lg="12" :xl="12">
                <el-form-item label="皮肤色度" prop="tone">
                  <el-select v-model="baseInfo.tone" clearable placeholder="请选择皮肤色度"
                  :popper-append-to-body="false" class="photoRegister_formItem_input">
                    <el-option v-for="dict in dict.type.sys_skin_tone" :key="dict.value" :label="dict.label"
                      :value="dict.value" />
                  </el-select>
                </el-form-item>
              </el-col>
              <el-col :xs='24' :sm="12" :md="12" :lg="12" :xl="12">
                <el-form-item label="顾客分类" prop="customerSort">
                  <el-select v-model="baseInfo.customerSort" clearable placeholder="请选择顾客分类"
                  :popper-append-to-body="false" class="photoRegister_formItem_input">
                    <el-option v-for="dict in dict.type.sys_patient_sort" :key="dict.value" :label="dict.label"
                      :value="dict.value" />
                  </el-select>
                </el-form-item>
              </el-col>

              <el-col :xs='24' :sm="12" :md="12" :lg="12" :xl="12">
                <el-form-item class="formItemRed" label="就诊门诊" prop="deptId">

                  <treeselect v-model="baseInfo.deptId" :defaultExpandLevel="Infinity" :disabled="isdeptAble" :disableInput="true"
                  :disableFlattening="true" :searchable="false"  :disable-branch-nodes="true" :normalizer="normalizer" :options="deptOptions" placeholder="请选择就诊门诊"
                    class="photoRegister_formItem_input" />
                </el-form-item>
              </el-col>

              <el-col :xs='24' :sm="24" :md="24" :lg="24" :xl="24" v-if="false">
                <el-form-item label="备注" prop="remark" class="remarkContainers"
                  :class="device == 'mobile' ? 'active' : ''">
                  <el-input v-model="baseInfo.remark" placeholder="请输入内容" class="photoRegister_formItem_input2"
                    type="textarea" :class="device == 'mobile' ? 'active' : ''"></el-input>
                </el-form-item>
              </el-col>

            </el-row>
          </div>
          </el-form>
          <div class="dialog-footer">
            <el-button @click="resetLoad" class="clearBtn">清 空</el-button>
            <el-button v-if="!isRegister" class="registerBtn rightBtn" @click="getDeptTreeAndLoginChecked(5)">
              登 记
            </el-button>
            <el-button @click="getDeptTreeAndLoginChecked(6)" class="registerBtn rightBtn" v-if="isRegister">立即拍照
            </el-button>
          </div>
        
        </div>
       
        
      </div>
      <!-- 根据身份证号、姓名、手机号查询多个病人时需要选择 -->
      <!-- 选择顾客 -->
      <el-dialog v-dialogDrag :class="device !== 'mobile' ? '' : 'active'" :close-on-click-modal="false"
        :visible.sync="patientVisible" :width="device !== 'mobile' ? '40%' : '85%'"
        class="nopaddingDailog photoPaitentDailog" title="选择顾客">
        <div class="formBox">
          <el-table :data="patientVisibleList" border style="width: 100%">
            <el-table-column :show-overflow-tooltip="true" align="center" label="顾客姓名" prop="patientName" sortable />
            <el-table-column :show-overflow-tooltip="true" align="center" label="顾客手机号" prop="patientPhone" sortable />
            <el-table-column align="center" label="性别" prop="sex" sortable>
              <template slot-scope="scope">
                <dict-tag :options="dict.type.sys_user_sex" :value="scope.row.sex" />
              </template>
            </el-table-column>
            <el-table-column align="center" label="年龄" prop="birthDateCopy" sortable width="80" />
            <el-table-column align="center" class-name="small-padding fixed-width" fixed="right" label="操作" width="100">
              <template slot-scope="scope">
                <el-button icon="el-icon-caret-right" size="mini" type="text" class="paitentBoxBtn"
                  @click="getDeptTreeAndLoginChecked(4, scope.row)">点击选择
                </el-button>
              </template>
            </el-table-column>
          </el-table>
        </div>
      </el-dialog>

      <div class="dec" v-if="isSkin">
        Copyright © 上海市皮肤病医院提供技术支持
      </div>

      <div class="dec" v-else>
        <!-- 医院信息展示 -->
        <!-- <div class="headerContainers_hospitalName">
           <div class="headerContainers_title">{{ hospital.deptName }}</div>
       </div> -->
        <div class="headerContainers_title">{{ hospital.deptName }}</div>
        Copyright © 霏图皮博士提供技术支持
      </div>

    </div>
    <!-- @click="loginDialog = false" -->
    <div class="logoinDailog" v-if="loginDialog">
      <login @loginSucess="reload()"></login>
    </div>
  </div>
</template>

<script>
import QRCode from 'qrcodejs2'
import login from '@/views/components/login.vue'
import { getToken } from "@/utils/auth";
import { mapGetters } from "vuex";
import Treeselect from "@riophae/vue-treeselect";
import "@riophae/vue-treeselect/dist/vue-treeselect.css";
import { addressJson } from "@/api/patients/personal";
import { listDept, getDeptInfo } from "@/api/system/dept";
import { getCameraInfoByequipmentNumber } from "@/api/cameraSetting/cameraSetting";
import Cookies from "js-cookie";
import {
  addVisit,
  listVisitTip,
  getVisitStatus,
  getDetailVisit,
  getProjectMsgInfos,
  updateMsgInfos,
  delCheckinCode
} from "@/api/patientRegistration/registrationList";

const { body } = document
const WIDTH = 1080 // refer to Bootstrap's responsive design
//自定义校验规则
var checkIdCard = (rule, value, cb) => {
  const regIdCard =
    /^[1-9]\d{5}(18|19|([23]\d))\d{2}((0[1-9])|(10|11|12))(([0-2][1-9])|10|20|30|31)\d{3}[0-9Xx]$/;
  if (regIdCard.test(value)) {
    return cb();
  }
  cb(new Error("您输入的身份证号码不是有效格式"));
};

var checkPatientPhone = (rule, value, cb) => {
  const regPatientPhone = /^1[3|4|5|6|7|8|9][0-9]\d{8}$/;
  if (regPatientPhone.test(value)) {
    return cb();
  }
  cb(new Error("您输入的手机号码不是有效格式"));
};
const dicts = [
  "sys_diagnosis_status",
  "sys_user_sex",
  "sys_patient_properties",
  "sys_skin_tone",
  "sys_patient_sort",
  "sys_outpatient_clinic",
  "sys_general_questionnaire",
  "sys_patient_reason",
]
export default {
  name: "photoRegister",
  dicts: getToken() ? dicts : [],
  components: {
    Treeselect,
    login

  },
  props: {},
  data() {
    return {
      tableData: [],
      loginDialog: false,
      isRegister: false,
      isSFZ: true,
      deptOptions: undefined,
      checkinCode: undefined,
      // 顾客信息
      baseInfo: {
        checkinCode: undefined,
        address: undefined,
        area: undefined,
        birthDate: undefined,
        cardNumber: undefined,
        cityId: undefined,
        countyId: undefined,
        customerSort: undefined,
        deptId: undefined, // deptId: 0,
        hospitalId: undefined,
        diagnosis: undefined,
        doctorId: undefined,
        doctorTime: undefined, //"2023-03-09T11:42:21.539Z"
        idNum: undefined,
        job: undefined,
        patientId: undefined,
        patientName: undefined,
        patientPhone: undefined,
        properties: "0",
        provinceId: undefined,
        questionnaireStatus: undefined,
        referee: undefined,
        refereeTime: undefined, //2023-03-09T11:42:21.539Z
        remark: undefined,
        sex: undefined,
        status: undefined,
        tone: undefined,
        visitId: undefined,
        visitNum: undefined,
        wxNum: undefined,
        isNeedVisi: undefined,
        gather: 1,
      },
      // 省市区
      areaList: [],
      //是否有身份证号
      isIdNum: true,
      // 表单校验
      baseInfoFormRules: {
        idNum: [
          {
            required: true,
            message: "身份证号不能为空",
            trigger: "blur",
          },
          { validator: checkIdCard, trigger: "blur" },
        ],
        patientName: [
          {
            required: true,
            message: "姓名不能为空",
            trigger: "blur",
          },
        ],
        sex: [
          {
            required: true,
            message: "性别不能为空",
            trigger: "blur",
          },
        ],
        birthDate: [
          {
            required: true,
            message: "出生年月不能为空",
            trigger: "blur",
          },
        ],
        patientPhone: [
          {
            required: true,
            message: "手机号不能为空",
            trigger: "blur",
          },
          { validator: checkPatientPhone, trigger: "blur" },
        ],
        properties: [
          {
            required: true,
            message: "顾客性质不能为空",
            trigger: "blur",
          },
        ],
        deptId: [
          {
            required: true,
            message: "就诊科室不能为空",
            trigger: "blur",
          },
        ],

      },
      baseInfoFormRulesA: {
        cardNumber: [
          {
            required: true,
            message: "就诊科室不能为空",
            trigger: "blur",
          },
        ],
      },
      // 禁止修改
      baseInfoInput: false,
      queryParams: {
        patientId: '',
        pageNum: 1,
        pageSize: 2,
        hospitalId: '',
        action: 'photo'
      },
      patientVisibleList: [],
      waitConsultationList: [],
      patientVisible: false,
      device: '',
      isShowIDStatus: false,
      photoParams: {
        patientId: '',//顾客id
        visitNum: '',//顾客编号
        patientName: '',//顾客姓名
        sex: '',//性别 0 男  1 女
        sexName: '',//性别 0 男  1 女
        status: '',//当前状态  0  待咨询   1 已咨询待诊断   3 治疗中  4 治疗已结束

      },
      InternCenterlogo:'',
      avatarLogo: '',
      avatarLogoImg: '',
      cameraNum: '',
      // deptId: '',
      isdeptAble: false,
      isAcneSection:false,//false,
      isSkin: false,
      isShanyi: false,
      isInternCenter:false,//国际医学中心
      isfeitu:false,
      //isInternCenter:true,//国际医学中心
      personcenter: '',
      personleft: '',
      personright: '',
      pifubinglogo: '',
      shanyilogo: '',
    }
  },
  computed: {
    ...mapGetters(["dept", "hospital", 'userId', 'nickName', 'token', 'deptId', 'avatar']),
  },
  watch: {},

  beforeCreate() {
    console.log("执行")
  },
  beforeMount() {
    window.addEventListener('resize', this.$_resizeHandler)
  },
  beforeDestroy() {
    window.removeEventListener('resize', this.$_resizeHandler)
  },
  created() {

  },
  mounted() {
    let vm = this
    window['getFeituCameraNum'] = function (a) {
      vm.getCameraNum(a)
    }
    this.$_resizeHandler()
    console.log(this.hospital)
    if (getToken()) {
      this.getDeptTree();

    } else {
      this.loginDialog = true
    }
    this.queryParams.hospitalId=this.hospital.parentId==0?'':this.hospital.parentId==100?this.hospital.deptId:this.hospital.parentId
    this.getAddressData();
    this.avatarLogo =
      this.hospital.hospitalLogo == "" || this.hospital.hospitalLogo == null
        ? require("@/assets/images/companyTitle1.png")
        : process.env.VUE_APP_BASE_API + this.hospital.hospitalLogo;
    this.avatarLogoImg = require("@/assets/images/companyTitle1.png")
    // document.documentElement.style.zoom=2
    this.personcenter = require("@/assets/images/personcenter.jpg")
    this.personleft = require("@/assets/images/personleft.jpg")
    this.personright = require("@/assets/images/personright.jpg")
    this.pifubinglogo = require("@/assets/images/pifulogo.png")
    this.shanyilogo = require("@/assets/images/shanyi.jpg")
    this.InternCenterlogo=require("@/assets/images/InternCenterlogo.jpg")
    this.getQR()
  },

  methods: {
    //生成二维码
    getQR(){
      

      
      this.$nextTick(() => {
        if(this.$refs.qrCodeDiv){
        let urlText="https://www.baidu.com/"
        new QRCode(this.$refs.qrCodeDiv, {
          text: urlText,//url地址  文本等需要转换为二维码的内容
          width: 150,
          height:150,
          colorDark: "#CC8764", //二维码颜色
          colorLight: "#ffffff", //二维码背景色
          correctLevel: QRCode.CorrectLevel.L, //容错率，L/M/H
        });
      }
      }); 
    },
    goToHref(){
      this.$message.warning('跳转逻辑~')
      // window.location.href = "https://www.baidu.com/"
    },
    getDeptEvent() {
      console.log("/***********")
      console.log(this.hospital)
      let deptId = this.hospital.parentId == 0 ? '' : (this.hospital.parentId == 100 ? this.hospital.deptId : this.hospital.parentId)
      if (deptId) {
        getDeptInfo(deptId).then(response => {
          if (response.code == 200) {
            let data = response.data
            if (data.registrationIdCardFlag == 1) {
              this.isShowIDStatus = true
            } else {
              this.isShowIDStatus = false
            }
          }
        })
      }

    },
    confirmIsIdNum() {
      console.log(this.isIdNum)
      if (!this.isIdNum) {
        this.$confirm(
          `请确认该顾客无身份证?系统自动生成一个随机数!`,
          "提示",
          {
            confirmButtonText: "确定",
            cancelButtonText: "取消",
            type: "warning",
            showClose: false,
            showCancelButton: false,
            closeOnClickModal: false, //是否可以点击空白处关闭弹窗
          }
        )
          .then((content) => {
            this.isIdNum = false;
            this.baseInfo.idNum = "98" + Date.now();
            this.baseInfoInput = true;
          })
          .catch((error) => {
            return;
          });
      } else {
        this.baseInfo.idNum = ''
        this.isIdNum = true;
        this.baseInfoInput = false;
      }
    },
    reloadPage() {
      location.reload(); // 重新加载当前页面
    },
    loginOut() {//退出登录
      this.$confirm(`是否切换登录账号？`, "提示", {
        customClass: 'photoRegisterconfirmDialog',//传入class
        confirmButtonText: "重新登录",
        cancelButtonText: "取消",
        type: "warning",
        dangerouslyUseHTMLString: true,
        closeOnClickModal: false,
        showClose: false,
        center: true
      })
        .then((content) => {//重新登录
          this.loginDialog = true
        })
        .catch((error) => {
          return;
        });
    },
    registAndPhotoEvent() {
      if (this.baseInfo.patientName && this.tableData && this.tableData.length > 0) {
        console.log(this.baseInfo)
        this.baseInfo.properties = 2 //体检
        addVisit(this.baseInfo).then((response) => {
          if (response.code == 200) {
            let data = response.data
            this.confirmPatient(data, 3)
          }
        });
      } else {
        this.$message.warning('请输入体检号,获取拍照基本信息~')
        return false
      }
    },
    resetLoadInput() {
      this.resetLoad()
    },
    updateMsgInfosEvent() {
      if (!this.baseInfo.checkinCode) {
        this.$message.warning('请输入体检号')
        return false
      }
      updateMsgInfos({ checkinCode: this.baseInfo.checkinCode, action: 'photo' }).then((response) => {
        if (response.code == 200) {
          if (response.data) {
            this.$confirm(`当前体检号已完成拍照,是否重新拍照，将替换之前的拍照？`, "提示", {
              customClass: 'photoRegisterconfirmDialog',//传入class
              confirmButtonText: "重新拍照",
              cancelButtonText: "取消",
              type: "warning",
              dangerouslyUseHTMLString: true,
              closeOnClickModal: false,
              showClose: false,
              center: true
            })
              .then((content) => {//重新拍照
                let dataparams = {
                  deptId: this.baseInfo.deptId,
                  checkinCode: this.baseInfo.checkinCode,
                  action: 'photo'
                }
                delCheckinCode(dataparams).then((response) => {
                  if (response.code == 200) {
                    let data = response.data
                    //this.confirmPatient(data, 3)
                    this.getProjectMsgInfosEvent(1)
                  } else if (response && response.code === 401) {
                    this.$message.error('无效的会话，或者会话已过期，请重新登录~')
                    this.loginDialog = true
                  } else {
                    if (response.msg != '操作成功') {
                      this.$message.warning(response.msg)
                    }

                  }
                });


              })
              .catch((error) => {

                return;
              });
            // this.$message.warning('该体检号已完成拍照，无效重复拍照~')
          } else {
            this.getProjectMsgInfosEvent()
          }

        } else if (response && response.code === 401) {
          this.$message.error('无效的会话，或者会话已过期，请重新登录~')
          this.loginDialog = true
        } else {
          if (response.msg != '操作成功') {
            this.$message.warning(response.msg)
          }

        }
      })
    },
    getProjectMsgInfosEvent(ptype) {// =1直接拍照
      if (!this.baseInfo.checkinCode) {
        this.$message.warning('请输入体检号')
        return false
      }
      getProjectMsgInfos({ checkinCode: this.baseInfo.checkinCode, action: 'photo' }).then((response) => {
        if (response.code == 200) {
          let data = response.data
          //Sex 1
          if (data) {
            this.baseInfo.idNum = data.IdCard,
              this.baseInfo.checkinCode = data.CheckinCode,
              this.baseInfo.birthDate = this.getDateBirth(data.DateOfBirth),
              this.baseInfo.sex = data.Sex == 2 ? 1 : 0,
              this.baseInfo.patientName = data.Name,
              this.baseInfo.patientPhone = data.MobilePhone ? data.MobilePhone : '15200000000'
            this.tableData = []
            this.tableData.push(this.baseInfo)
            this.checkinCode = data.CheckinCode
            // this.getDeptTreeAndLoginChecked(2, this.baseInfo.idNum)
            if (ptype == 1) {
              this.registAndPhotoEvent()
            }
          } else {
            this.$message.warning('请输入有效的体检号~')
          }
        } if (response && response.code === 401) {
          this.$message.error('无效的会话，或者会话已过期，请重新登录~')
          this.loginDialog = true
        } else {
          if (response.msg != '操作成功') {
            this.$message.warning(response.msg)
          }
        }
      })
    },
    getDateBirth(date) {
      if (date) {
        let time = date.split(' ')[0]
        var strtime = time.split('/').join('-'); //时间转换
        return strtime
      } else {
        return ''
      }
    },
    getCameraSetting(type) {
      this.isdeptAble = false
      // if(this.isAcneSection){
      //   this.getPatientList()
      // }else{
      if (localStorage.getItem('cameraNum')) {
        this.cameraNum = localStorage.getItem('cameraNum')
        getCameraInfoByequipmentNumber({ equipmentNumber: this.cameraNum, action: 'photo' }).then((response) => {
          if (response.code == 200) {
            let data = response.data
            if (data.deptId) {
              this.queryParams.deptId = data.deptId
              this.baseInfo.deptId = data.deptId
              this.isdeptAble = true
            }
            if (type == 1) {
              this.getPatientList()
            }

          } else {
            if (type == 1) {
              this.getPatientList()
            }
          }
        })
      } else {
        if (type == 1) {
          this.getPatientList()
        }
      }
    },
    getCameraNum(a) {
      this.cameraNum = a ////a //改变data中定义的值
      console.log("打印编号：" + a)
      localStorage.setItem('cameraNum', this.cameraNum)


      if (this.cameraNum == '000AF5550671') {  //皮肤病医院
        this.isAcneSection = true
      }
      if (this.cameraNum == '000AF5C10978') {  //凤凰馨院
        this.isShanyi = true
      }
      if(this.cameraNum == '000AF54E0E37'){//上海国际医学中心
        this.isInternCenter=true
      }
      if(this.cameraNum == '000AF5E17C2F'){//霏图演示设备
        this.isfeitu=true
      }
      //isfeitu演示环境
       //000AF54E0E37  国际医学中心 InternCenter
      //  this.$modal.msgSuccess("打印编号："+a);

    },
    handleClickButton() {
      setTimeout(() => {
        // 执行失焦操作
        // 处理其他操作
      }, 100);
    },
    reload() {
      this.loginDialog = false
      location.reload()
    },
    $_isMobile() {
      const rect = body.getBoundingClientRect()
      return rect.width - 1 < WIDTH
    },
    $_resizeHandler() {
      if (!document.hidden) {
        const isMobile = this.$_isMobile()
        //store.dispatch('app/toggleDevice', isMobile ? 'mobile' : 'desktop')
        this.device = isMobile ? 'mobile' : 'desktop'
        console.log(this.device)
      }

    },
    //查看本地照片库
    goPhotoAll() { //  YF.mainHomePage(var json)
      // this.$message.warning('跳转照片检索页面')
      //this.$modal.msgSuccess('跳转照片检索页面成功~')
      const username = Cookies.get("username");
      const password = Cookies.get("passwordNum");
      console.log(password)

      let params = {
        loginData: {
          token: getToken(), //登录token
          nickName: this.nickName,//登录账号昵称
          userId: this.userId,//登录用户id
          deptId: this.deptId,//所属部门id
          hospitalId: this.hospital.deptId,//所属医院id
          hospitalName: this.hospital.deptName,//所属医院名称
          avatar: location.origin + this.avatar,//登录头像
          account: username,
          password: password
        }
      }
      console.log(JSON.stringify(params))
      this.resetLoad()
      window.YF.mainHomePage(JSON.stringify(params))
      // this.$bridge.callhandler('YF.mainHomePage', JSON.stringify(params), (data) => {
      //     // 处理app回调返回给vue的数据
      //     this.$modal.msgSuccess('跳转照片检索页面成功~')

      // })
    },
    //立即拍照
    goToPhoto() { //YF.takeCamera(var json)  立即拍照
      const username = Cookies.get("username");
      const password = Cookies.get("passwordNum");
      // this.$message.warning('跳转拍照页面')
      // vue调app原生方法
      let params = {
        loginData: {
          token: getToken(), //登录token
          nickName: this.nickName,//登录账号昵称
          userId: this.userId,//登录用户id
          deptId: this.deptId,//所属部门id
          hospitalId: this.hospital.deptId,//所属医院id
          hospitalName: this.hospital.deptName,//所属医院名称
          avatar: location.origin + this.avatar,//登录头像
          account: username,
          password: password
        },
        customerInfos: {

          // patientId: '',//顾客id
          // visitNum: '',//顾客编号
          // patientName: '',//顾客姓名
          // sex: '',//性别 0 男  1 女
          // sexName: '',//性别 0 男  1 女
          // status: '',//当前状态  0  待咨询   1 已咨询待诊断   3 治疗中  4 治疗已结束
          ...this.photoParams
        }
      }
      console.log(params)
      console.log(JSON.stringify(params))
      this.resetLoad()
      window.YF.takeCamera(JSON.stringify(params))
      // this.$bridge.callhandler('YF.takeCamera', JSON.stringify(params), (data) => {
      //     // 处理app回调返回给vue的数据
      //     this.$modal.msgSuccess('跳转拍照页面~')
      // })

    },
    //卡号
    submitFormAcneSection() {
      // if(this.baseInfo.cardNumber){
      //   if(!this.baseInfo.idNum){
      //     this.baseInfo.idNum = "98" + Date.now();
      //   }
      // }
      if (this.baseInfo.cardNumber) {
        this.$refs["baseInfoFormA"].validate((valid) => {
          if (valid) {
            if (!this.baseInfo.idNum) {
              this.baseInfo.idNum = "98" + Date.now();
            }
            const currentDate = new Date();
            const year = currentDate.getFullYear();
            const month = (currentDate.getMonth() + 1).toString().padStart(2, '0'); // 月份从0开始，所以要加1，并补零
            const day = currentDate.getDate().toString().padStart(2, '0'); // 补零
            // const idNumLast = this.baseInfo.idNum.slice(-4)
            // const formattedDateTime = year + month + day + idNumLast;


            this.baseInfo.patientName = "皮肤检测" + this.baseInfo.cardNumber
            this.baseInfo.patientPhone = "15200000000"
            this.baseInfo.gather = 1
            this.baseInfo.properties = '1'

            if (!this.baseInfo.birthDate) {
              this.baseInfo.birthDate = '1990-08-01'
            }
            if (!this.baseInfo.sex) {
              this.baseInfo.sex = "1";
            }
            let that = this
            console.log('this.deptOptions---', this.deptOptions)
            console.log('that.deptId', that.deptId)
            if (this.deptOptions.length == 1) {
              this.baseInfo.deptId = this.deptOptions[0].deptId;
              if (this.deptOptions[0].parentId != 0) {
                this.baseInfo.hospitalId = this.deptOptions[0].parentId;
              }
            } else {
              this.deptOptions.forEach(function (ele) {
                if (ele.parentId == that.deptId) {
                  that.baseInfo.hospitalId = that.deptId
                  that.baseInfo.deptId = ele.deptId
                }
              });
            }

            this.baseInfo.status = "0";
            this.baseInfo.visitNum = null;
            delete this.baseInfo.visitId;
            console.log("this.baseInfo--addVisit", this.baseInfo);
            addVisit(this.baseInfo).then((response) => {
              if (response.code == 200) {
                let data = response.data
                this.$modal.msgSuccess("登记成功~，请点击拍照");
                this.confirmPatient(data, 3)

              }
            });
          }



        })
      }

    },


    //身份证号
    changeBirthDate(idCard) {
      console.log("changeBirthDate--", idCard);
      if (!idCard) {
        return;
      }
      var birthday = "";
      var genderCode = ""; // 性别代码
      if (idCard != null && idCard != "") {
        // 一代身份证号码长度为15位（第15位为性别代码）
        if (idCard.length == 15) {
          birthday = "19" + idCard.substr(6, 6);
          genderCode = idCard.charAt(14);
        } else if (idCard.length == 18) {
          // 二代身份证号码长度为18位（第17位为性别代码）
          birthday = idCard.substr(6, 8);
          genderCode = idCard.charAt(16);
        }
        if (genderCode && !isNaN(genderCode)) {
          // 两代身份证号码的性别代码都为男奇女偶
          if (parseInt(genderCode) % 2 == 0) {
            this.baseInfo.sex = "1";
          } else {
            this.baseInfo.sex = "0";
          }
        }
        birthday = birthday.replace(/(.{4})(.{2})/, "$1-$2-");
      }
      this.baseInfo.birthDate = birthday;

      this.getVisitStatusList(idCard, 0);

    },
    selectable(time) {
      var strtime = time.replace("/-/g", "/"); //时间转换
      var date1 = new Date(strtime); //现在时间
      var date2 = new Date();
      var d2 =
        date2.getFullYear() +
        "/" +
        (date2.getMonth() + 1) +
        "/" +
        date2.getDate();
      var date3 = new Date(d2);
      //判断时间是否有效
      return date1 > date3 ? true : false;
    },
    /** 提交按钮 */
    submitForm: function () {
      this.$refs["baseInfoForm"].validate((valid) => {
        if (!!this.baseInfo.area) {
          this.baseInfo.provinceId = String(this.baseInfo.area[0]);
          this.baseInfo.cityId = String(this.baseInfo.area[1]);
          this.baseInfo.countyId = String(this.baseInfo.area[2]);
        }
        let deptOptionsArr = this.deptOptionsArr;
        if (valid) {
          let that = this;

          deptOptionsArr.forEach(function (ele) {
            console.log(ele.deptId);
            if (ele.deptId == that.baseInfo.deptId) {
              console.log(ele);
              console.log("___专病————");
              if (
                that.getSplit(ele.ancestors).length != 2 &&
                that.getSplit(ele.ancestors).length != 1
              ) {
                that.baseInfo.hospitalId = ele.parentId;
              } else {
                that.baseInfo.hospitalId = ele.deptId;
              }
            }
          });
          // 判断以下日期是否有效
          if (this.baseInfo.birthDate) {
            if (this.selectable(this.baseInfo.birthDate)) {
              console.log(this.selectable(this.baseInfo.birthDate));
              this.$message.warning("请检查身份证信息或者生日日期");
              return false;
            }
          }

          this.baseInfo.status = "0";
          this.baseInfo.visitNum = null;
          delete this.baseInfo.visitId;
          console.log("this.baseInfo--addVisit", this.baseInfo);
          addVisit(this.baseInfo).then((response) => {
            if (response.code == 200) {
              let data = response.data
              this.$modal.msgSuccess("登记成功~，请点击拍照");
              this.confirmPatient(data, 3)


            }
          });
        }
      });
    },
    //姓名查询
    blurPatientName(value) {
      if (!this.baseInfo.idNum) {
        if (!this.baseInfoInput) {
          this.confirmIdNumShow = false;
          this.getVisitStatusList(value, 1);
          console.log("执行")
        }
      }
    },
    confirmIdNum(row) {//选择顾客进行查询

      this.getVisitStatusList(row.idNum, 0);
      this.patientVisible = false
    },
    // 查询是否登记完成
    getVisitStatusList(value, type) {
      if (!value) {
        return;
      }
      getVisitStatus(value, type).then((response) => {
        if (response.code == 200) {
          let data = response.data
          this.waitConsultationList = data; //查出此病人所有未治疗结束的记录
          if (data == false) {
            this.baseInfo = response.oldVisit;
          }
          if (data.length > 0) {
            if (data.length == 1) {
              if (data[0].status == '4') { //结束，重新登记
                this.confirmPatient(data[0], 1)
              } else { //未结束直接前往拍照
                this.confirmPatient(data[0], 2)


              }
            } else {
              this.patientVisible = true;
              this.patientVisibleList = data;
              this.patientVisibleList.forEach((item) => {
                item.birthDateCopy = parseInt(
                  (new Date() - new Date(this.parseTime(item.birthDate))) /
                  (1000 * 60 * 60 * 24 * 365)
                );
              });
            }

          } else {
            if (type == 0) {

              if (this.isShanyi) { ////调用登记接口获取对应信息

              } else if (this.isAcneSection) {

              } else {
                this.$message.warning('您搜索的信息暂无登记记录~，请输入基本信息完成登记~')
              }
            }

          }
        }
      });
    },
    //  // 获取顾客登记记录列表
    getPatientList() {
      if (this.queryParams.patientId) {
        listVisitTip(this.queryParams).then((res) => {
          if (res && res.code === 200) {
            let data = res.rows
            console.log(data)
            if (data && data.length > 0) {
              if (data[0].status == '4') { //结束，重新登记
                this.confirmPatient(data[0], 1)
              } else { //未结束直接前往拍照
                this.confirmPatient(data[0], 2)


              }

            } else {
              this.$message.warning('您输入的顾客Id暂不存在~，请输入基本信息完成登记~')
            }
          } else {
            if (res && res.code === 401) {
              this.$message.error('无效的会话，或者会话已过期，请重新登录~')

              this.loginDialog = true
            } else {
              this.$message.warning(res.msg)
            }

          }


        }
        );
      } else {
        if (!this.isAcneSection) {
          this.$message.warning('请输入顾客的Id~')

        }
      }

    },
    confirmPatientSelect(value) {
      this.patientVisible = false;
      this.baseInfo = value;
      this.baseInfo.area = [
        Number(this.baseInfo.provinceId),
        Number(this.baseInfo.cityId),
        Number(this.baseInfo.countyId),
      ];
      this.baseInfo.questionnaireStatus = "1";
      this.baseInfoInput = true;
      this.isIdNum = false;
    },
    confirmPatient(row, actionType) {
      this.reset();
      this.baseInfoInput = true;
      const visitId = row.visitId
      getDetailVisit(visitId).then((response) => {
        this.baseInfo = response.data;
        this.baseInfo.area = [
          Number(response.data.provinceId),
          Number(response.data.cityId),
          Number(response.data.countyId),
        ];

        if (actionType == 2) { // 无需重新登记，直接进入拍照
          this.isRegister = true
          this.photoParams = {
            birthday: this.baseInfo.birthDate,
            patientPhone: this.baseInfo.patientPhone,
            patientId: this.baseInfo.patientId,//病人id
            visitNum: this.baseInfo.visitNum,//顾客编号
            patientName: this.baseInfo.patientName,//顾客姓名
            sex: this.baseInfo.sex,//性别
            sexName: this.baseInfo.sex == 0 ? '男' : '女',//性别 0 男  1 女
            status: this.baseInfo.status,//当前状态  0  待咨询   1 已咨询待诊断   3 治疗中  4 治疗已结束
          }
          this.$confirm(`您当前已有一条未结束的登记信息，可直接进入拍照`, "提示", {
            customClass: 'photoRegisterconfirmDialog',//传入class
            confirmButtonText: "立即拍照",
            cancelButtonText: "取消",
            type: "warning",
            dangerouslyUseHTMLString: true,
            closeOnClickModal: false,
            showClose: false,
            center: true
          })
            .then((content) => {
              this.isRegister = true
              this.getDeptTreeAndLoginChecked(6) //前往拍照
            })
            .catch((error) => {
              this.isRegister = true

              return;
            });

        } else if (actionType == 3) {
          this.isRegister = true
          this.photoParams = {
            birthday: this.baseInfo.birthDate,
            patientPhone: this.baseInfo.patientPhone,
            patientId: this.baseInfo.patientId,//病人id
            visitNum: this.baseInfo.visitNum,//顾客编号
            patientName: this.baseInfo.patientName,//顾客姓名
            sex: this.baseInfo.sex,//性别
            sexName: this.baseInfo.sex == 0 ? '男' : '女',//性别 0 男  1 女
            status: this.baseInfo.status,//当前状态  0  待咨询   1 已咨询待诊断   3 治疗中  4 治疗已结束
          }
          this.getDeptTreeAndLoginChecked(6)
        } else {
          this.isRegister = false
        }
      });

    },
    resetLoad() {// 重置表单操作
      this.queryParams.patientId = ''
      this.reset()
    },
    // 表单重置
    reset() {
      this.isRegister = false
      this.isSFZ = true;
      this.checkinCode = undefined;
      this.baseInfo = {
        checkinCode: undefined,
        address: undefined,
        area: undefined,
        birthDate: undefined,
        cardNumber: undefined,
        cityId: undefined,
        countyId: undefined,
        customerSort: undefined,
        deptId: undefined, // deptId: 0,
        hospitalId: undefined,
        diagnosis: undefined,
        doctorId: undefined,
        doctorTime: undefined, //"2023-03-09T11:42:21.539Z"
        idNum: undefined,
        job: undefined,
        patientId: undefined,
        patientName: undefined,
        patientPhone: undefined,
        properties: "0",
        provinceId: undefined,
        questionnaireStatus: undefined,
        referee: undefined,
        refereeTime: undefined, //2023-03-09T11:42:21.539Z
        remark: undefined,
        sex: undefined,
        status: undefined,
        tone: undefined,
        visitId: undefined,
        visitNum: undefined,
        wxNum: undefined,
        isNeedVisi: undefined,
        gather: 1,
      };
      this.tableData = []
      this.resetForm("baseInfoForm");
      this.getDeptTree();
    },
    cancel() {

    },
    // 获取地区
    getAddressData() {
      addressJson().then((res) => {
        this.areaList = res.data;
      });
    },
    getSplit(str) {
      return str.split(",");
    },
    /** 查询科室下拉树结构 */
    getDeptTree() {
      let that = this
      listDept().then((response) => {
        if (response && response.code === 200) {
          let data = response.data;
          this.deptOptionsArr = data;
          this.getDeptEvent()
          if (this.getSplit(this.dept.ancestors).length == 3) {
            //3级用户
            data.push(this.hospital); //默认加一个上级医院
          }
          this.deptOptions = this.handleTree(data, "deptId")[0].children;
          // console.log("999999999999999999999999999999999")
          // console.log(this.deptOptions)
          if (this.isShanyi) { // 凤凰馨院默认显示科室 医院
            if (this.deptOptions.length == 1) {
              this.baseInfo.deptId = this.deptOptions[0].deptId;
              if (this.deptOptions[0].parentId != 0) {
                this.baseInfo.hospitalId = this.deptOptions[0].parentId;
              }
            } else {
              this.deptOptions.forEach(function (ele) {

                if (ele.deptName == "凤凰馨院") {
                  console.log("进来了凤凰馨院~")
                  console.log(ele)
                  that.baseInfo.hospitalId = ele.deptId
                  that.baseInfo.deptId = ele.children[0].deptId
                }
              });
            }

          } else {

            if (this.deptOptions.length == 1) {
              this.baseInfo.deptId = this.deptOptions[0].deptId;
              if (this.deptOptions[0].parentId != 0) {
                this.baseInfo.hospitalId = this.deptOptions[0].parentId;
              }
            }
          }

          this.getCameraSetting(0)
        } else {
          if (response && response.code === 401) {
            this.$message.error('无效的会话，或者会话已过期，请重新登录~')

            this.loginDialog = true
          } else {
            this.$message.warning(response.msg)
          }
        }

      });
    },
    inputIdNum(event) {
      this.isRegister = false
    },
    //验证是否登录有效
    getDeptTreeAndLoginChecked(type, value) { // type  1  搜索顾客id   2 搜索 顾客身份证   3  姓名   4 确认选择顾客  5 提交   6 拍照
      let params = {
        action: 'photo'
      }

      listDept(params).then((response) => {
        if (response && response.code === 200) {
          if (type == 1) {
            this.getCameraSetting(1)
          } else if (type == 2) {
            this.changeBirthDate(value)
          } else if (type == 3) {
            this.blurPatientName(value)
          } else if (type == 4) {
            this.confirmIdNum(value)
          } else if (type == 5) {
            this.submitForm()
          } else if (type == 6) {
            this.goToPhoto()
          } else if (type == 7) {
            this.goPhotoAll()
          } else if (type == 8) {
            this.submitFormAcneSection()
          }
        } else {
          if (response && response.code === 401) {
            this.$message.error('无效的会话，或者会话已过期，请重新登录~')

            this.loginDialog = true
          } else {
            this.$message.warning(response.msg)
          }
        }

      });


    },
    /** 转换部门数据结构 */
    normalizer(node) {
      if (node.children && !node.children.length) {
        delete node.children;
      }
      return {
        id: node.deptId,
        label: node.deptName,
        children: node.children,
      };
    },
  }
}
</script>
<style scoped lang="scss">
.photoregisterImgContainers{
  position: relative;
  .photoregisterImg{
  width:100%;
  display: block;
}
.qrcodeContainers{
  position: absolute;
  top:32px;
  right:140px;
  width:170px;
  height:170px;
  border:1px solid #CC8764;
  padding:10px;

}
}

.photoDevice {
  position: absolute;
  top:0px;
  left: 10px;
  font-size: 28px;
  color: red;
  z-index: 10;
  cursor: pointer;
}

.refreshBtn {
  position: absolute;
  top: 12px;
  right: 50px;
  font-size: 28px;
  color: #DAA170;
  z-index: 10;
  cursor: pointer;
}

.refreshBtn1 {
  position: absolute;
  top: 12px;
  right: 12px;
  font-size: 28px;
  color: #DAA170;
  z-index: 10;
  cursor: pointer;
  transform: rotate(90deg)
}

.refreshBtn2 {
  position: absolute;
  top: 12px;
  right: 90px;
  font-size: 28px;
  color: #DAA170;
  z-index: 10;
  cursor: pointer;

}

.headerFixed {
  position: fixed;
  top: 5px;
  left: 50%;
  transform:translateX(-50%);
  display: flex;
  align-items: center;

  &_image {
    width: 40px;
    height: 40px;
    border-radius: 40px;
    margin-right: 10px;
  }

  &_text {
    font-size: 20px;
    font-weight: 700;
  }
}

.registerBtnContainers {
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 40px;
}

.hcqStyle3 {
  background: #EEE url() repeat;
  text-shadow: 5px -5px #CC8764, 4px -4px white;
  font-weight: bold;
  -webkit-text-fill-color: transparent;
  -webkit-background-clip: text
}

.hcqStyle6 {
  color: #CC8764;
  letter-spacing: 0;
  text-shadow: 0px 1px 0px #ddd, 0px 2px 0px #ccc, 0px 3px 0px #bbb, 0px 4px 0px #aaa, 0px 5px 0px #999, 0px 6px 0px #888, 0px 7px 0px #777, 0px 8px 7px #001135
}

.hcqStyle7 {
  // font-family: cursive;
  // text-shadow: 6px 2px 2px #999;
  // color: rgba(207, 163, 224, 1); //#CC8764;
  color: #9476D0;
}

.hcqStyle8 {
  color: #9476D0;//rgba(207, 163, 224, 1); //#CC8764;

}

.searchAllBtn {
  position: absolute;
  top: 0px;
  right: 0px;
  display: flex;
  align-items: center;
  background: linear-gradient(270deg, #CC8764 0%, #DAA170 100%);
  box-shadow: 0px 8px 20px 0px rgba(206, 139, 102, 0.5);
  color: #fff;
  padding: 15px 40px;
  font-size: 32px;
  border-radius: 8px;

  .homeIcon {
    margin-right: 8px;
    font-size: 40px;
  }
}

.logoinDailog {
  position: fixed;
  width: 100%;
  height: 100vh;
  top: 0px;
  left: 0px;
  z-index: 999;
  background: rgba(0, 0, 0, .3);
  cursor: pointer;
}

.header_title {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-weight: 600;
  // font-style: italic;
}

// .headerContainers_hospitalName{
//     position: fixed;
//     bottom:5px;
//     right:5px;
//     font-size:12px;
//     display:flex;
//     align-items: center;
//     .headerContainers_image{
//         width:30px;
//         height:30px;
//         border-radius: 30px;
//     }
//     .headerContainers_title{

//     }
// }
.header {
  position: absolute;
  top: 0px;
  left: 50%;
  transform: translateX(-50%);
  width: 100%;
  text-align: center;

}

.headerContainers {
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 56px;
  color: #3D3D3D;
  line-height: 160px;

  .header_image {
    height: 72px;
    margin-right: 20px;
    border-radius:10px;
  }


}

.headerContainers_title {
  font-size: 14px;
  color: #CC8764;
  text-align: center;
  line-height: 20px;
}

.dec {
  position: absolute;
  bottom: 0px;
  left: 50%;
  transform: translateX(-50%);
  width: 100%;
  text-align: center;
  font-size: 28px;
  line-height: 40px;
  color: #3D3D3D;
}

.backBtn {
  display: flex;
  align-items: center;
  font-size: 20px;
  color: #fff;
}

.registerBtn:hover,
.registerBtn:focus {
  color: #fff;
  border: none;
}

.clearBtn {
  padding: 0px 50px;
  font-size: 28px;
  height: 72px;
  border-radius: 8px;
}

.registerBtn {
  background: linear-gradient(270deg, #CC8764 0%, #DAA170 100%);
  box-shadow: 0px 8px 20px 0px rgba(206, 139, 102, 0.5);
  color: #fff;
  padding: 0px 10px;
  font-size: 28px;
  height: 72px;
  border-radius: 8px;
  border: none;

}

.rightBtn {
  padding: 0px 50px;
  margin-left: 60px;
}

.registerBtn.active {
  background: #999;
}

.photoBtn {
  background: blue;
  color: #fff;
}

.photoBtn.active {
  background: #999;
}

.photoRegisterBg {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  padding-top: 160px;
  font-size: 28px !important;
  //background-image: url("../assets/images/login-background.jpg");
  //background-image: url("../assets/images/loginBg.jpg");
  //background-image: url("../assets/images/loginBg.jpg");
  //background-size: cover;
  background: #eff0f4;
  min-height: 100vh;
  padding-bottom: 72px;
  // background: linear-gradient(225deg, #ffb6b6 4%, #FFFFFF 75%);
}

.photoRegister_formItem_input {
  //width: 202px;
  width: 100%;
  ::v-deep .el-select-dropdown__item{
    font-size:28px!important;
    line-height: 50px!important;
    height:50px!important;
  }
  ::v-deep .vue-treeselect__menu{
     .vue-treeselect__option{
      font-size:28px!important;
    line-height: 50px!important;
    height:50px!important;
     }
  }
  ::v-deep .el-picker-panel{
    line-height: 50px!important;
  }
  ::v-deep .el-date-picker__header{
    font-size:24px!important;
    .el-picker-panel__icon-btn{
      font-size:24px!important;
    }
    .el-date-picker__header-label{
      font-size:24px!important;
    }
  }
  ::v-deep .el-date-table{
    font-size:24px!important;
    td{
      width:52px!important;
      height:50px!important;
      span{
        width:40px!important;
        height:40px!important;
        line-height: 40px!important;
      }
    }
  }
  
  ::v-deep .el-cascader-node{
    font-size:24px!important;
    height:40px!important;
    line-height: 40px!important;
  }
  ::v-deep .el-cascader__dropdown{
    right:0px!important;
    left: auto!important;
  }
  ::v-deep .popper__arrow{
    right:5px!important;
    left: auto!important;
  }
}

.photoRegister_formItem_input2 {
  //width: 404px;
  width: 100%;
  min-height: 100px;

}

.photoRegister_formItem_input2.active {
  width: 100%;
}

::v-deep .inputBold .el-input__inner {
  font-weight: bold;
  color: #606266;
  
}

.dialog-footer {
  margin-top:15px;
  display: flex;
  justify-content: center;
  align-items: center;
}

.photoRegisterBg .el-form-item {
  margin-bottom: 36px !important;
  height: 72px !important;
}

.photoRegisterBg .remarkContainers {
  height: auto !important;

}

.photoRegisterBg .el-input__inner {
  border: none !important;
  background:#F0F1F4!important;
}

.photoRegisterBg .remarkContainers.active {
  width: 100%;
}

.photoRegisterBoxs-content .el-form-item__label {
  font-size: 16px;
}

.photoRegisterBoxs {
  // background: #E1E2E5;
  // padding: 40px 20px;
  // padding-bottom:20px;
  // border-radius: 20px;
  // border-top-left-radius: 0px;
  // border-top-right-radius: 0px;
  // box-shadow: 40px 40px 50px 0px rgba(0, 0, 0, 0.05), -32px -32px 40px 0px rgba(255, 255, 255, 0.3);
  ::v-deep .el-form-item__error{
    font-size:24px!important;
  }
  ::v-deep .vue-treeselect__control{
    background:#F0F1F4!important;
    height:72px!important;
    .vue-treeselect__control-arrow{
      width:18px;
      height:18px;
    }
  }
}
.photoRegisterBoxs_div{
  background:#fff;
  margin-top:20px;
  padding:20px;
  padding-bottom:5px;
  border-radius: 20px;
}

.dialogTitle {
  position: relative;
  margin-bottom:30px;
  height: 72px;
  display: flex;
  align-items: center;

}

.titleLine {
  width: 12px;
  height: 48px;
  display: block;
  border-radius: 8px;
  background: linear-gradient(270deg, #CC8764 0%, #DAA170 100%);
  box-shadow: 0px 8px 20px 0px rgba(206, 139, 102, 0.5);
  margin-right: 30px;
}

.dialogTitle .image {
  width: 100%;
}

.dialogTitle .name {
  color: #606266;
  font-weight: bold;
  font-size: 40px;


}

::v-deep .baseInfoContainers .el-table .el-table__cell {
  font-size: 20px !important;
  height: 50px !important;
}

::v-deep .baseInfoContainers .el-table th.el-table__cell {
  background: #DAA170;
  font-size: 20px !important;
  height: 50px !important;
}
</style>
<style>

.photoRegisterBg .el-textarea__inner {
  min-height: 180px !important;
  font-size: 32px;
}

.photoRegisterBg .el-input__suffix {
  right: 15px;
}

.photoRegister_formItem_radio {
  height: 72px !important;
  line-height: 72px !important;
  font-size: 28px;
  box-sizing: border-box;
}

.photoRegister_formItem_radio .el-radio__inner {
  font-size: 28px;
  width: 20px;
  height: 20px;
}

.photoRegister_formItem_radio .el-radio__label {
  font-size: 28px;
}

.photoRegisterBg .el-input__inner {
  border: none !important;
  height: 72px !important;
  line-height: 72px !important;
  font-size: 28px;
  padding-right: 50px;
  box-sizing: border-box;
  background:#F0F1F4!important;
}

.photoRegisterBg .el-input--medium .el-input__icon {
  font-size: 32px;
  height: 72px !important;
  line-height: 72px !important;
}

.photoRegisterBg .el-select__caret {
  height: 36px !important;
}

.photoRegisterBg .vue-treeselect__input {
  font-size: 32px !important;
  height: 72px !important;
  line-height: 72px !important;
}

.photoRegisterBg .vue-treeselect__single-value,
.photoRegisterBg .vue-treeselect__placeholder {
  font-size: 32px !important;
  height: 72px !important;
  line-height: 72px !important;
}

.photoRegisterBoxs-content .el-form-item__label {
  font-size: 32px;
  height: 72px !important;
  line-height: 72px !important;
}

.remarkContainers.active .el-form-item__content {
  width: calc(100% - 200px)
}

.remarkContainers .el-form-item__content {
  width: calc(100% - 200px)
}

.photoRegisterBoxs-content .el-form-item__content {
  width: calc(100% - 200px)
}

.photoRegisterBoxs-content .el-form-item {
  width: 100%;
}
.photoRegisterBoxs-content .shanyiForm .el-form-item__content  {
  width:calc(100% - 120px)!important;
}

.photoRegisterBoxs-content .formOther .el-form-item__content {
  width: calc(100% - 220px)
}

.photoRegisterconfirmDialog {
  background: #E1E2E5;
  border-radius: 15px;
  box-shadow: 40px 40px 50px 0px rgba(0, 0, 0, 0.05);
}

.photoRegisterconfirmDialog .el-message-box__message {
  font-size: 18px;
}

.photoRegisterconfirmDialog .el-message-box__btns button:nth-child(2) {
  margin-left: 50px;
  background: linear-gradient(270deg, #CC8764 0%, #DAA170 100%);
  box-shadow: 0px 4px 10px 0px rgba(206, 139, 102, 0.5);
  color: #fff;
  border: none;
}

.photoRegisterconfirmDialog .el-message-box__btns .el-button {
  font-size: 24px;
}

.photoPaitentDailog.nopaddingDailog .el-dialog {
  left: 50% !important;
  top: 50%;
  transform: translate(-50%, -50%);
  border-radius: 15px;
}

.photoPaitentDailog.nopaddingDailog .el-dialog .el-dialog__header {
  border-bottom: 1px solid #CC8764;
}

.photoPaitentDailog.nopaddingDailog .el-dialog .el-dialog__close {
  color: #CC8764;
}

.photoPaitentDailog.nopaddingDailog .el-dialog .el-dialog__header .el-dialog__title {
  color: #CC8764;
}

.photoPaitentDailog.nopaddingDailog .el-dialog .el-dialog__header .el-dialog__title::after {
  background-color: #fff;
  display: none;
}

.paitentBoxBtn {
  color: #CC8764;
}

.imageBox {
  display: flex;
  justify-content: space-around;
}

.imageBox .imageSmallBox {
  text-align: center;
  color: #606266;
}

.textBox .textBoxTitle {
  font-weight: bolder;
  color: #606266;
}

.textBox .textBoxLine {
  margin-left: 2em;
  color: #606266;

}
</style>
